import request from '@/utils/request'

// 查询其他出库列表
export function listIssueInternal(query) {
  return request({
    url: '/mes/wm/issueinternal/list',
    method: 'get',
    params: query
  })
}

// 查询其他出库详细
export function getIssueInternal(issueId) {
  return request({
    url: '/mes/wm/issueinternal/' + issueId,
    method: 'get'
  })
}

// 新增其他出库
export function addIssueInternal(data) {
  return request({
    url: '/mes/wm/issueinternal',
    method: 'post',
    data: data
  })
}

// 修改其他出库
export function updateIssueInternal(data) {
  return request({
    url: '/mes/wm/issueinternal',
    method: 'put',
    data: data
  })
}

// 删除其他出库
export function delIssueInternal(issueId) {
  return request({
    url: '/mes/wm/issueinternal/' + issueId,
    method: 'delete'
  })
}

//执行出库
export function execute(issueId) {
  return request({
    url: '/mes/wm/issueinternal/' + issueId,
    method: 'put'
  })
}

//确认
export function confirme(issueId) {
  return request({
    url: '/mes/wm/issueinternal/status/' + issueId,
    method: 'put'
  })
}

//审核
export function handleApprove(issueId) {
  return request({
    url: '/mes/wm/issueinternal/handleApprove/' + issueId,
    method: 'get'
  })
}
